﻿using L.UI.Base;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;

public class MaskPanel : BasePanel
{
    private void Start()
    {
        transform.SetAsLastSibling();
    }
    public float Process
    {
        set
        {
            m_Slider.value = value;
            processText.text = string.Format("{0:F0}%", value * 100);
        }
    }
    public string Info
    {
        set
        {
            infoText.text = value;
        }
    }

    [SerializeField]
    private Slider m_Slider;
    [SerializeField]
    private Text infoText;
    [SerializeField]
    private Text processText;
    [SerializeField]
    private Transform loadImage;


    [Range(0f, 360f)]
    public float speed = 5f;
    private void Update()
    {
        loadImage.Rotate(Vector3.forward, -speed * Time.deltaTime, Space.Self);
    }

}
